// api.js
import axios from 'axios';

const instance = axios.create({
    baseURL: 'http://localhost:8080'
});

// api.js
axios.interceptors.response.use(
    response => response,
    error => {
        console.error('API调用错误:', error.response || error.message);
        return Promise.reject(error);
    }
);


export default instance;
